/*
 * @Author: wnc
 * @Date: 2021-11-24 11:08:06
 * @Description: 法务模块路由
 */
import { RouteView } from '@/layouts'


// legal原来属于法务那边，后面改到物资这边来了
export default {
  path: '/legal',
  redirect: '/legal/branch-contract',
  component: RouteView,
  meta: {
    title: '法务',
    icon: '../../src/assets/building.png',
    permission: ['form', 'table']
  },
  children: [
    //   {
    //     path: '/legal/branch-bidding',
    //     name: 'RranchBidding',
    //     component: RouteView,
    //     meta: { title: '计划管理', hideHeader: true, permission: ['form', 'table'] },
    //     // meta: { title: '分包招议标管理', hideHeader: true, permission: ['form', 'table'] },
    //     redirect: '/legal/branch-bidding/demandplanning',
    //     hideChildrenInMenu: true,
    //     children: [
    // {
    //   path: '/legal/branch-bidding/demandplanning',
    //   name: 'DemandPlanning',
    //   component: () => import('@/views/Legal/branchBidding/planManagement'),
    //   meta: { title: '分包招标需求计划管理', hidden: true, permission: ['form', 'table'] }
    // },
    // {
    //   path: '/legal/branch-bidding/plandiscussion',
    //   name: 'PlanDiscussion',
    //   component: () => import('@/views/Legal/branchBidding/planDiscussion'),
    //   meta: { title: '分包招议标计划管理', hidden: true, permission: ['form', 'table'] }
    // },
    // {
    //   path: '/legal/branch-bidding/plandiscussion/detail',
    //   name: 'plandiscussionDetail',
    //   component: () => import('@/views/Legal/branchBidding/planDiscussion/details'),
    //   meta: { title: '分包招议标计划详情', hidden: true, permission: ['form', 'table'], noTab: true }
    // },
    // {
    //   path: '/legal/branch-bidding/complete',
    //   name: 'DemandPlanningComplete',
    //   component: () => import('@/views/Legal/branchBidding/planComplete'),
    //   meta: { title: '分包招议标完成情况', hidden: true, permission: ['form', 'table'] }
    // },
    // {
    //   path: '/legal/branch-bidding/details',
    //   name: 'DemandPlanningDetails',
    //   component: () => import('@/views/Legal/branchBidding/planComplete/details'),
    //   meta: { title: '分包招议标完成情况详情', hidden: true, permission: ['form', 'table'], noTab: true }
    // }
    // ]
    // },
    {
      path: '/legal/branch-contract',
      name: 'RranchContract',
      component: RouteView,
      meta: {
        title: '合同管理',
        hideHeader: true,
        permission: ['form', 'table']
      },
      redirect: '/legal/branch-contract/total-package-contract/index',
      hideChildrenInMenu: true,
      children: [
        {
          path: 'YunzhuApiPermission',
          name: 'YunzhuApiPermission',
          component: () => import('@/views/Legal/branchContract/YunzhuApiPermission'),
          meta: {
            title: '云筑API配置',
            hidden: true
          }
        },
        {
          path: 'dosage',
          name: 'acceptanceDosage',
          component: () => import('@/views/materials/acceptance/dosage'),
          meta: {
            title: '物资用量确认单',
            hidden: true
          }
        },
        {
          hidden: 'true',
          path: 'dosage/add',
          name: 'acceptanceDosageAdd',
          component: () => import('@/views/materials/acceptance/dosage/add'),
          meta: {
            title: '物资用量确认单',
            hidden: true,
            noTab: true,
            parent: {
              path: '/legal/branch-contract/dosage',
              title: '物资用量确认单'
            }
          }
        },
        {
          path: '/material/contract/review',
          name: 'contractReview',
          component: () => import('@/views/materials/contract/review'),
          meta: {
            title: '物资合同评审',
            hidden: true
          }
        },
        {
          hidden: 'true',
          path: '/material/contract/review/add',
          name: 'contractReviewAdd',
          component: () => import('@/views/materials/contract/review/add'),
          meta: {
            title: '物资合同评审',
            hidden: true,
            noTab: true,
            parent: {
              path: '/material/contract/review',
              title: '物资合同评审'
            }
          }
        },
        {
          path: '/material/contract/clarificaiton',
          name: 'contractClarificaiton',
          component: () => import('@/views/materials/contract/clarificaiton'),
          meta: {
            title: '合同交底记录',
            hidden: true
          }
        },
        {
          hidden: 'true',
          path: '/material/contract/clarificaiton/add',
          name: 'contractClarificaitonAdd',
          component: () => import('@/views/materials/contract/clarificaiton/add'),
          meta: {
            title: '合同交底记录',
            hidden: true,
            noTab: true,
            parent: {
              path: '/material/contract/clarificaiton',
              title: '合同交底记录'
            }
          }
        },
        {
          path: '/material/contract/parameter',
          name: 'contractParameter',
          component: () => import('@/views/materials/contract/parameter'),
          meta: {
            title: '物资合同台账',
            hidden: true
          }
        },
        {
          hidden: 'true',
          path: '/material/contract/parameter/detail',
          name: 'contractParameterDetail',
          component: () => import('@/views/materials/contract/parameter/detail'),
          meta: {
            title: '物资合同台账',
            noTab: true
          }
        },
        {
          hidden: 'true',
          path: '/material/contract/parameter/amend_record',
          name: 'contractParameterAmendRecord',
          component: () => import('@/views/materials/contract/parameter/amend_record.vue'),
          meta: {
            title: '物资合同台账补录',
            noTab: true
          }
        },
        {
          path: '/legal/branch-contract/management',
          name: 'contractManagement',
          component: () => import('@/views/Legal/branchContract/management'),
          meta: {
            title: '分包合同管理'
          }
        },
        {
          hidden: 'true',
          path: '/legal/branch-contract/editOrdinaryContract',
          name: 'editOrdinaryContract',
          component: () => import('@/views/Legal/branchContract/management/editOrdinaryContract'),
          meta: {
            title: '分包合同',
            hidden: true,
            permission: ['form', 'table'],
            noTab: true,
            parent: {
              path: 'management',
              title: '分包合同管理'
            }
          }
        },
        {
          hidden: 'true',
          path: '/legal/branch-contract/editSupplementaryagreement',
          name: 'editSupplementaryAgreement',
          component: () => import('@/views/Legal/branchContract/management/editSupplementaryAgreement'),
          meta: {
            title: '补充协议',
            hidden: true,
            permission: ['form', 'table'],
            noTab: true,
            parent: {
              path: 'management',
              title: '分包合同管理'
            }
          }
        },
        {
          path: '/legal/branch-contract/editCloudBuildInput',
          name: 'editCloudBuildInput',
          component: () => import('@/views/Legal/branchContract/management/editCloudBuildInput.vue'),
          meta: {
            title: '云筑补录',
            noTab: true
          }
        },
        {
          hidden: 'true',
          path: '/legal/branch-contract/cloud-build-network/index',
          name: 'cloudBuildNetworkIndex',
          component: () => import('@/views/Legal/branchContract/cloudBuildNetwork'),
          meta: {
            title: '云筑网合同入库',
            hidden: true,
            permission: ['form', 'table']
          }
        },
        {
          hidden: 'true',
          path: '/legal/branch-contract/cloud-build-network/add',
          name: 'cloudBuildNetworkAdd',
          component: () => import('@/views/Legal/branchContract/cloudBuildNetwork/add'),
          meta: {
            title: '云筑网合同入库',
            hidden: true,
            permission: ['form', 'table'],
            noTab: true,
            parent: {
              path: 'index',
              title: '云筑网合同入库'
            }
          }
        },
        {
          path: '/legal/branch-contract/total-package-contract/index',
          name: 'totalPackageContractIndex',
          component: () => import('@/views/Legal/branchContract/totalPackageContract/index'),
          meta: {
            title: '总包合同管理',
            hidden: true,
            permission: ['form', 'table']
          }
        },
        {
          hidden: 'true',
          path: '/legal/branch-contract/total-package-contract/add',
          name: 'totalPackageContractAdd',
          component: () => import('@/views/Legal/branchContract/totalPackageContract/add'),
          meta: {
            title: '总包合同管理',
            hidden: true,
            permission: ['form', 'table'],
            noTab: true,
            parent: {
              path: 'index',
              title: '总包合同管理'
            }
          }
        },
        {
          hidden: 'true',
          path: '/legal/branch-contract/total-package-contract/detail',
          name: 'totalPackageContractDetail',
          component: () => import('@/views/Legal/branchContract/totalPackageContract/detail'),
          meta: {
            title: '总包合同管理',
            hidden: true,
            permission: ['form', 'table'],
            noTab: true,
            parent: {
              path: 'index',
              title: '总包合同管理'
            }
          }
        },
        // {
        //   hidden: 'true',
        //   path: '/legal/branch-contract/total-package-contract/change',
        //   name: 'totalPackageContractChange',
        //   component: () => import('@/views/Legal/branchContract/totalPackageContract/change'),
        //   meta: {
        //     title: '总包合同变更',
        //     hidden: true,
        //     // permission: ['form', 'table'],
        //     noTab: true,
        //     // parent: { path: 'index', title: '总包合同变更' }
        //   }
        // },
        {
          path: '/legal/branch-contract/otherTypesContract',
          name: 'otherTypesContract',
          meta: {
            title: '其他类合同管理'
          },
          component: () => import('@/views/Legal/branchContract/otherTypesContract/index')
        },
        {
          path: '/legal/branch-contract/otherTypesContract/detail',
          name: 'otherTypesContractDetail',
          meta: {
            title: '其他类合同管理',
            noTab: true
          },
          component: () => import('@/views/Legal/branchContract/otherTypesContract/detail')
        },
        {
          path: '/legal/branch-contract/otherTypesContract/add',
          name: 'otherTypesContractAdd',
          meta: {
            title: '其他类合同管理',
            noTab: true
          },
          component: () => import('@/views/Legal/branchContract/otherTypesContract/add')
        },
        {
          path: 'legal/branch-contract/otherTypesContract/seal',
          name: 'otherTypesContractSeal',
          meta: {
            title: '其他类合同管理',
            noTab: true
          },
          component: () => import('@/views/Legal/branchContract/otherTypesContract/seal')
        }
        // {
        //   path: '/legal/branch-contract/other-type/index',
        //   name: 'otherTypeIndex',
        //   component: () => import('@/views/Legal/branchContract/otherType/index'),
        //   meta: { title: '其他类合同', hidden: true, permission: ['form', 'table'] }
        // },
        // {
        //   hidden: 'true',
        //   path: '/legal/branch-contract/other-type/add',
        //   name: 'otherTypeAdd',
        //   component: () => import('@/views/Legal/branchContract/otherType/add'),
        //   meta: {
        //     title: '其他类合同', hidden: true, permission: ['form', 'table'], noTab: true,
        //     parent: { path: 'index', title: '其他类合同' }
        //   }
        // },
        // {
        //   hidden: 'true',
        //   path: '/legal/branch-contract/other-type/detail',
        //   name: 'otherTypeDetail',
        //   component: () => import('@/views/Legal/branchContract/otherType/detail'),
        //   meta: {
        //     title: '其他类合同详情', hidden: true, permission: ['form', 'table'], noTab: true,
        //     parent: { path: 'index', title: '其他类合同' }
        //   }
        // },
      ]
    },
    {
      path: '/legal/caselawyerLetter',
      name: 'caseLawyerLetter',
      component: RouteView,
      meta: {
        title: '案件与函件管理',
        hideHeader: true,
        permission: ['form', 'table']
      },
      redirect: '/legal/caselawyerLetter/case/management',
      hideChildrenInMenu: true,
      children: [
        {
          path: '/legal/caselawyerLetter/case/management',
          name: 'caseManagement',
          component: () => import('@/views/Legal/caseLawyerLetter/caseManagement'),
          meta: {
            title: '执行案件管理',
            hidden: true,
            permission: ['form', 'table']
          }
        },
        {
          path: '/legal/caselawyerLetter/case/management/add',
          name: 'caseManagementAdd',
          component: () => import('@/views/Legal/caseLawyerLetter/caseManagement/addCase'),
          meta: {
            title: '新增执行案件',
            hidden: true,
            permission: ['form', 'table'],
            noTab: true
          }
        },
        {
          path: '/legal/caselawyerLetter/case/management/edit',
          name: 'caseManagementEdit',
          component: () => import('@/views/Legal/caseLawyerLetter/caseManagement/addCase'),
          meta: {
            title: '编辑执行案件',
            hidden: true,
            permission: ['form', 'table'],
            noTab: true
          }
        },
        {
          path: '/legal/caselawyerLetter/case/management/update',
          component: () => import('@/views/Legal/caseLawyerLetter/caseManagement/UpdateCase.vue'),
          meta: {
            title: '执行案件',
            noTab: true
          }
        },
        {
          path: '/legal/caselawyerLetter/lawyerLetter',
          name: 'lawyerLetter',
          component: () => import('@/views/Legal/caseLawyerLetter/lawyerLetter'),
          meta: {
            title: '函件管理',
            hidden: true,
            permission: ['form', 'table']
          }
        },
        {
          path: '/legal/caselawyerLetter/lawyerLetter/edit',
          name: 'editlawyerLetter',
          component: () => import('@/views/Legal/caseLawyerLetter/lawyerLetter/editLawyerLetter'),
          meta: {
            title: '函件管理',
            hidden: true,
            permission: ['form', 'table'],
            noTab: true
          }
        },
        {
          path: '/legal/caselawyerLetter/lawyerLetter/details',
          name: 'lawyerLetterDetails',
          component: () => import('@/views/Legal/caseLawyerLetter/lawyerLetter/lawyerLetterDetails'),
          meta: {
            title: '函件详情',
            hidden: true,
            permission: ['form', 'table'],
            noTab: true
          }
        },
        {
          path: '/legal/caselawyerLetter/lawyerLetter/update',
          name: 'UpdateLawyerLetter',
          component: () => import('@/views/Legal/caseLawyerLetter/lawyerLetter/updateLawyerLetter'),
          meta: {
            title: '函件管理',
            hidden: true,
            permission: ['form', 'table'],
            noTab: true
          }
        },
        {
          path: '/legal/caselawyerLetter/lawyerLetter/riskManagement',
          name: 'LawyerLetterRiskManagement',
          component: () => import('@/views/Legal/caseLawyerLetter/lawyerLetter/riskManagement'),
          meta: {
            title: '律师函风险管理',
            hidden: true,
            permission: ['form', 'table'],
            noTab: true,
            parent: {
              path: '/legal/caselawyerLetter/lawyerLetter',
              title: '律师函管理'
            }
          }
        }
      ]
    },
    {
      path: '/legal/caseLawyerLetter/claimEstablishment',
      name: 'claimEstablishment',
      component: RouteView,
      meta: {
        title: '索赔管理',
        hideHeader: true,
        permission: ['form', 'table']
      },
      redirect: '/legal/caseLawyerLetter/claimEstablishment/index',
      hideChildrenInMenu: true,
      children: [
        {
          path: '/legal/caseLawyerLetter/claimEstablishment/index',
          name: 'claimEstablishmentManage',
          component: () => import('@/views/Legal/caseLawyerLetter/claimEstablishment'),
          meta: {
            title: '索赔管理',
            hidden: true,
            permission: ['form', 'table']
          }
        },
        {
          path: '/legal/caseLawyerLetter/claimEstablishment/add',
          name: 'claimEstablishmentAdd',
          component: () => import('@/views/Legal/caseLawyerLetter/claimEstablishment/editClaimEstablishment'),
          meta: {
            title: '索赔立项新增',
            hidden: true,
            permission: ['form', 'table'],
            noTab: true,
            parent: {
              path: 'index',
              title: '索赔管理'
            }
          }
        },
        {
          path: '/legal/caseLawyerLetter/claimEstablishment/details',
          name: 'claimEstablishmentDetails',
          component: () => import('@/views/Legal/caseLawyerLetter/claimEstablishment/claimEstablishmentDetails'),
          meta: {
            title: '索赔立项详情',
            hidden: true,
            permission: ['form', 'table'],
            noTab: true,
            parent: {
              path: 'index',
              title: '索赔管理'
            }
          }
        },
        {
          path: '/legal/caseLawyerLetter/claimEstablishment/advanceRecord',
          name: 'claimEstablishmentAdvanceRecord',
          component: () => import('@/views/Legal/caseLawyerLetter/claimEstablishment/advanceRecord'),
          meta: {
            title: '索赔推进记录',
            hidden: true,
            permission: ['form', 'table'],
            noTab: true,
            parent: {
              path: 'index',
              title: '索赔管理'
            }
          }
        }
      ]
    },
    {
      path: '/legal/risk',
      name: 'risk',
      component: RouteView,
      meta: {
        title: '风险管理',
        hideHeader: true,
        permission: ['form', 'table']
      },
      redirect: '/legal/risk/elementCheckList/index',
      hideChildrenInMenu: true,
      children: [
        {
          path: '/legal/risk/hideLoss/index',
          name: 'hideLossList',
          component: () => import('@/views/Legal/risk/hideLoss'),
          meta: {
            title: '潜亏风险'
          }
        },
        {
          path: '/legal/risk/list/index',
          name: 'riskList',
          component: () => import('@/views/Legal/risk/list'),
          meta: {
            title: '风险管理',
            hidden: true,
            permission: ['form', 'table']
          }
        },
        {
          path: '/legal/risk/list/add',
          name: 'riskListAdd',
          component: () => import('@/views/Legal/risk/list/add'),
          meta: {
            title: '风险列表新增',
            hidden: true,
            permission: ['form', 'table'],
            noTab: true,
            parent: {
              path: 'index',
              title: '风险列表'
            }
          }
        },
        {
          path: '/legal/risk/list/detail',
          name: 'riskListDetail',
          component: () => import('@/views/Legal/risk/list/detail'),
          meta: {
            title: '风险列表详情',
            hidden: true,
            permission: ['form', 'table'],
            noTab: true,
            parent: {
              path: 'index',
              title: '风险列表'
            }
          }
        },
        {
          path: '/legal/risk/elementCheckList/index',
          name: 'elementCheckList',
          component: () => import('@/views/Legal/risk/elementCheckList'),
          meta: {
            title: '风险要素清单',
            hidden: true,
            permission: ['form', 'table']
          }
        },
        {
          path: '/legal/risk/elementCheckList/add',
          name: 'elementCheckListAdd',
          component: () => import('@/views/Legal/risk/elementCheckList/add'),
          meta: {
            title: '风险要素清单新增',
            hidden: true,
            permission: ['form', 'table'],
            noTab: true,
            parent: {
              path: 'index',
              title: '风险要素清单'
            }
          }
        },
        {
          path: '/legal/risk/elementCheckList/detail',
          name: 'elementCheckListDetail',
          component: () => import('@/views/Legal/risk/elementCheckList/detail'),
          meta: {
            title: '风险要素清单详情',
            hidden: true,
            permission: ['form', 'table'],
            noTab: true,
            parent: {
              path: 'index',
              title: '风险要素清单'
            }
          }
        },
        {
          path: '/legal/risk/periodRisk/index',
          name: 'periodRiskList',
          component: () => import('@/views/Legal/risk/periodRisk'),
          meta: {
            title: '工期风险'
          }
        },
      ]
    }
  ]
}